package com.sq.partner.manager.dao.impl;

import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Repository;

import com.sq.partner.manager.dao.NlifeRationDao;
import com.sq.partner.manager.mybatis.model.NlifeRation;

/**
 *
 * @author zsm 2019年4月10日
 *
 */
@Repository
public class NlifeRationDaoImpl extends BaseDaoImpl implements NlifeRationDao{
	@Override
	public void addRation(NlifeRation ration) throws Exception {
		this.add("addRation", ration);
	}

	@SuppressWarnings("unchecked")
	@Override
	public List<NlifeRation> queryRationInfo(Map<String, Object> map)
			throws Exception {
		return this.queryList("queryRationInfo", map);
	}

	@Override
	public boolean deleteRationByParam(NlifeRation ration) throws Exception {
		return this.delete("deleteRationByProdCode", ration);
	}

	@Override
	public void updateRationInfoByParam(NlifeRation ration) throws Exception {
		this.update("updateRationInfoByParam", ration);
	}

	@Override
	public boolean deleteAllRationByProdCode(String prodCode) throws Exception {
		return this.delete("deleteAllRationByProdCode", prodCode);
	}

}
